import {
  post,
  get,
  put,
  dalete,
  postJosn,
  putone,
  patch,
  daleteJson,
  download
} from "../utils/request";

//分页查询商品活动列表
export function queryGoodsActivityList(data) {
  return post("/api/goods-service/v1/goodsActivity/queryGoodsActivityList",data);
  //   return post('http://10.51.4.222:18080/api/goods-service/v1/goodsActivity/queryGoodsActivityList', data);
}

//分页查询商品活动列表
export function updateGoodsActivityStatus(data) {
  return post("/api/goods-service/v1/goodsActivity/updateGoodsActivityStatus",data);
  //   return post('http://10.51.4.222:18080/api/goods-service/v1/goodsActivity/updateGoodsActivityStatus', data);
}

//查询中奖记录
export function queryWinningRecordList(data) {
  return post("/api/trade-service/v1/orderGift/queryOrderGiftDetail", data);
}

//批量发货 post
export function batchDeliverGoods(ids) {
  return post("/api/trade-service/v1/orderGift/updateBatch?ids=" + ids);
}

//查询中奖记录 Excel
export function queryWinningRecordListExcel(data) {
  return download("/api/trade-service/v1/orderGift/exportOrderGiftDetail",data);
}

//查询记录
export function queryServiceRecord(data) {
  return post("/api/member-service/v1/memberApplyRecord/queryServiceRecord", data);
}

//查询记录 Excel
export function exportServiceRecord(data) {
  return download("/api/member-service/v1/memberApplyRecord/exportServiceRecord", data);
}

//查询记录
export function queryListByArgs(data) {
  return post("/api/promotion-service/v1/WineRedPacket/queryListByArgs", data);
}

//查询记录 Excel
export function exportPacketDetail(data) {
  return download("/api/promotion-service/v1/WineRedPacket/exportPacketDetail", data);
}

//查询兑换记录
export function queryExchangeRecord(data) {
  return post("api/promotion-service/v1/WineRedPacket/queryExchangeRecord", data);
}

//审核兑换单 入参 uuid，exchangeStatus 审核状态 1通过，5不通过，rebackReason 驳回原因
export function reviewExchange(data) {
  return post("/api/promotion-service/v1/WineRedPacket/reviewExchange", data);
}


//查询兑换记录 Excel
export function exportExchangeRecord(data) {
  return download("/api/promotion-service/v1/WineRedPacket/exportExchangeRecord", data);
}


//查询兑换记录 导入Excel
export function importExchangeRecord(data) {
  return post("/api/promotion-service/v1/WineRedPacket/importExchangeRecord", data);
}
//查询兑换记录详情
export function conversionInfo(data) {
  return get("/api/promotion-service/v1/WineRedPacket/conversionInfo?exchangeSeq="+data.exchangeSeq);
}

//查询转赠记录
export function queryPresenterListByArgs(data) {
  return post("/api/promotion-service/v1/WineRedPacket/queryPresenterListByArgs", data);
}

//查询转赠记录 Excel
export function exportPacketDetail2(data) {
  return download("/api/promotion-service/v1/WineRedPacket/exportPacketDetail", data);
}

//查询转赠记录详情
export function receiveRedPacket(data) {
  return get("api/promotion-service/v1/WineRedPacket/receiveRedPacket?presenterSeq="+data.presenterSeq);
}

//查询礼品中奖记录
export function queryPointsRecordList(data) {
  return post("/api/promotion-service/v1/promotionBuyFree/qryConvertOrder", data);
}

//礼品批量发货 post
export function sendBonuspointConvert(data) {
  return post("/api/promotion-service/v1/BonuspointConvert/sendBonuspointConvert", data);
}

//查询礼品中奖记录 Excel
export function getBonuspointConvertExcel(data) {
  return download("/api/promotion-service/v1/promotionBuyFree/getBonuspointConvertExcel", data);
}


//查询活动用户信息记录
export function queryMembersOrder(data) {
  return post("/api/data-service/v1/dataTradeSearch/queryMembersOrder", data);
}

//查询活动用户信息记录 Excel
export function ExcelMembersOrder(data) {
  return download("/api/data-service/v1/dataTradeSearch/ExcelMembersOrder", data);
}